<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>远程关机</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no">
    <link rel="stylesheet" type="text/css" href="../static/css/bootstrap.4.5.3.min.css">
<style>
    .div1{
        margin: 15px auto 0;
        width: 90%;
    }
</style>
</head>
<script>
    function selectDown() {
        var stk = document.getElementById("Select1");
        var a1 = document.getElementById("shutDownRestart");
        var a2 = document.getElementById("shutDownHref");
        a1.href = '/restart?time='+stk.value
        a2.href = '/shutDown?time='+stk.value
    }
</script>
<body>
    <div class="div1">
          <div class="form-group">
            <label for="Select1">时间选择</label>
            <select class="form-control" id="Select1" oninput="selectDown()">
              <option value="1">1分钟后关机</option>
              <option value="2">2分钟后关机</option>
              <option value="3">3分钟后关机</option>
              <option value="5">5分钟后关机</option>
              <option value="8">8分钟后关机</option>
              <option value="10">10分钟后关机</option>
            </select>
          </div>

          <div class="row">
            <div class="col-sm">
                <a href="/shutDown?time=1" style="margin-top: 8px;" id="shutDownHref" class="btn btn-outline-danger btn-lg btn-block">关机</a>
            </div>
            <div class="col-sm">
                <a href="/restart?time=1" style="margin-top: 8px;" id="shutDownRestart" class="btn btn-outline-info btn-lg btn-block">重启</a>
            </div>
            <div class="col-sm">
                <a href="/realTime" style="margin-top: 8px;" id="shutDownRestart" class="btn btn-outline-dark btn-lg btn-block">查看电脑当前界面</a>
            </div>
          </div>

        </div>
</body>
</html>